The Exact PRF-Security of NMAC and HMAC

نویسندگان

  • Peter Gazi
  • Krzysztof Pietrzak
  • Michal Rybár
چکیده

NMAC is a mode of operation which turns a fixed input-length keyed hash function f into a variable input-length function. A practical single-key variant of NMAC called HMAC is a very popular and widely deployed message authentication code (MAC). Security proofs and attacks for NMAC can typically be lifted to HMAC. NMAC was introduced by Bellare, Canetti and Krawczyk [Crypto’96], who proved it to be a secure pseudorandom function (PRF), and thus also a MAC, assuming that (1) f is a PRF and (2) the function we get when cascading f is weakly collision-resistant. Unfortunately, HMAC is typically instantiated with cryptographic hash functions like MD5 or SHA-1 for which (2) has been found to be wrong. To restore the provable guarantees for NMAC, Bellare [Crypto’06] showed its security based solely on the assumption that f is a PRF, albeit via a non-uniform reduction. – Our first contribution is a simpler and uniform proof: If f is an ε-secure PRF (against q queries) and a δ-non-adaptively secure PRF (against q queries), then NMAC is an (ε + `qδ)-secure PRF against q queries of length at most ` blocks each. – We then show that this ε+`qδ bound is basically tight. For the most interesting case where `qδ ≥ ε we prove this by constructing an f for which an attack with advantage `qδ exists. This also violates the bound O(`ε) on the PRF-security of NMAC recently claimed by Koblitz and Menezes. – Finally, we analyze the PRF-security of a modification of NMAC called NI [An and Bellare, Crypto’99] that differs mainly by using a compression function with an additional keying input. This avoids the constant rekeying on multi-block messages in NMAC and allows for a security proof starting by the standard switch from a PRF to a random function, followed by an informationtheoretic analysis. We carry out such an analysis, obtaining a tight `q/2 bound for this step, improving over the trivial bound of `q/2. The proof borrows combinatorial techniques originally developed for proving the security of CBC-MAC [Bellare et al., Crypto’05]. We also analyze a variant of NI that does not include the message length in the last call to the compression function, proving a `q/2 bound in this case.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Generic Security of NMAC and HMAC with Input Whitening

HMAC and its variant NMAC are the most popular approaches to deriving a MAC (and more generally, a PRF) from a cryptographic hash function. Despite nearly two decades of research, their exact security still remains far from understood in many different contexts. Indeed, recent works have re-surfaced interest for generic attacks, i.e., attacks that treat the compression function of the underlyin...

متن کامل

An Update on the Analysis and Design of NMAC and HMAC Functions

In this paper, we investigate the issues in the analysis and design of provably secure message authentication codes (MACs) Nested MAC (NMAC) and Hash based MAC (HMAC) proposed by Bellare, Canetti and Krawczyk. First, we provide security analysis of NMAC using weaker assumptions than stated in its proof of security. This analysis shows that, theoretically, one cannot further weaken the assumptio...

متن کامل

General Distinguishing Attacks on NMAC and HMAC with Birthday Attack Complexity

Kim et al. [4] and Contini et al. [3] studied on the security of HMAC and NMAC based on HAVAL, MD4, MD5, SHA-0 and SHA-1. Especially, they considered the distinguishing attacks. However, they did not describe generic distinguishing attacks on NMAC and HMAC. In this paper, we describe the generic distinguishers to distinguish NMAC and HMAC with the birthday attack complexity and we prove the sec...

متن کامل

Quantum Security of NMAC and Related Constructions

We prove the security of NMAC, HMAC, AMAC, and the cascade construction with fixed input-length as quantum-secure pseudorandom functions (PRFs). Namely, they are indistinguishable from a random oracle against any polynomial-time quantum adversary that can make quantum superposition queries. In contrast, many blockcipherbased PRFs including CBC-MAC were recently broken by quantum superposition a...

متن کامل

Full Key-Recovery Attacks on HMAC/NMAC-MD4 and NMAC-MD5

At Crypto ’06, Bellare presented new security proofs for HMAC and NMAC, under the assumption that the underlying compression function is a pseudo-random function family. Conversely, at Asiacrypt ’06, Contini and Yin used collision techniques to obtain forgery and partial key-recovery attacks on HMAC and NMAC instantiated with MD4, MD5, SHA-0 and reduced SHA-1. In this paper, we present the firs...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2014